package com.stream.utils.validator;

import com.stream.utils.RRException;
import org.apache.commons.lang3.StringUtils;

/**
 * 数据效验
 * Created by yebaokang on 2017/5/26.
 */
public abstract class Assert {
    public static void isBlank(String value, String message) {
        if (StringUtils.isBlank(value)) {
            throw new RRException(message);
        }
    }

    public static void isNull(Object o, String message) {
        if (o == null) {
            throw new RRException(message);
        }
    }
}
